package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.ReservationMapper;
import com.ruoyi.system.domain.Reservation;
import com.ruoyi.system.service.IReservationService;

/**
 * 包房预约Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-07-04
 */
@Service
public class ReservationServiceImpl implements IReservationService 
{
    @Autowired
    private ReservationMapper reservationMapper;

    /**
     * 查询包房预约
     * 
     * @param reservationRoomId 包房预约主键
     * @return 包房预约
     */
    @Override
    public Reservation selectReservationByReservationRoomId(String reservationRoomId)
    {
        return reservationMapper.selectReservationByReservationRoomId(reservationRoomId);
    }

    /**
     * 查询包房预约列表
     * 
     * @param reservation 包房预约
     * @return 包房预约
     */
    @Override
    public List<Reservation> selectReservationList(Reservation reservation)
    {
        return reservationMapper.selectReservationList(reservation);
    }

    /**
     * 新增包房预约
     * 
     * @param reservation 包房预约
     * @return 结果
     */
    @Override
    public int insertReservation(Reservation reservation)
    {
        return reservationMapper.insertReservation(reservation);
    }

    /**
     * 修改包房预约
     * 
     * @param reservation 包房预约
     * @return 结果
     */
    @Override
    public int updateReservation(Reservation reservation)
    {
        return reservationMapper.updateReservation(reservation);
    }

    /**
     * 批量删除包房预约
     * 
     * @param reservationRoomIds 需要删除的包房预约主键
     * @return 结果
     */
    @Override
    public int deleteReservationByReservationRoomIds(String[] reservationRoomIds)
    {
        return reservationMapper.deleteReservationByReservationRoomIds(reservationRoomIds);
    }

    /**
     * 删除包房预约信息
     * 
     * @param reservationRoomId 包房预约主键
     * @return 结果
     */
    @Override
    public int deleteReservationByReservationRoomId(String reservationRoomId)
    {
        return reservationMapper.deleteReservationByReservationRoomId(reservationRoomId);
    }
}
